Twitter Web Intent
クエリパラメータ
text
URL-encoded
url
URL-encoded
hashtags
など
code:example.py
from urllib.parse import urlencode
query_parameters = {
"text": "Python Boot Campで全国にPythonの環を広げよう!",
"hashtags": "pycamp",
}
print(f"{web_intent_url}?{urlencode(query_parameters)}")
リンクをブラウザで開くとtextをツイートできる状態でTwitterが開く
Twitterのドキュメントにある%20にencodeされないが、正常に動作しているか気になった